package com.pie.face_pie.tool;

public class Result {
    private Integer code;
    private String msg;
    private String data;

    public static Result success() {
        return new Result(1,null,null);
    }
    public static Result success(String msg,String data) {
        return new Result(1,null,data);
    }

    public static Result fail(String msg) {
        return new Result(0,msg,null);
    }

    public Result() {
    }

    public Result(Integer code, String msg, String data) {
        this.code = code;
        this.msg = msg;
        this.data = data;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public String getData() {
        return data;
    }

    public void setData(String data) {
        this.data = data;
    }
}
